/** 数据列表配置 */
const reportList = ref([
  {
    name:'支付订单数',
    value:666,
    bgColor:'#FFF7E5',
    textColor:'#FF6B00',
    tipText:'活动有效期内，参与了新人优惠活动的订单总数'
  },
  {
    name:'实付金额',
    value:1666.00,
    bgColor:'#F0F2F8',
    textColor:'#0C268C',
    tipText:'活动有效期内，参与了新人优惠活动的商品实际支付金额'
  },
  {
    name:'支付会员数',
    value:666,
    bgColor:'#E8F9EF',
    textColor:'#18BF5B',
    tipText:'活动有效期内，参与了新人优惠活动的会员总数'
  }
])
export const useActivityDataPage = () => {
  return {
    reportList
  }
}

export const useCurd = () => {
  const tableLoading = ref(false)
  const tableData = ref([])
  const handlerSearch = (id)=>{
    try{
      tableLoading.value = true
      tableData.value = [{
        id:'1',
        name:'活动名称'
      }]
    }finally{
      tableLoading.value = false
    }
  }
  const tableConfig = ref([
    {
      label:'销售单号',
      prop:'name',
      minWidth:148
    },
    {
      label:'实收金额',
      prop:'name',
      minWidth:160
    },
    {
      label:'会员姓名',
      prop:'name',
      minWidth:160
    },
    {
      label:'会员手机号',
      prop:'name',
      minWidth:160
    },
    {
      label:'结算时间',
      prop:'name',
      minWidth:160
    },
    {
      label:'订单来源',
      prop:'name',
      minWidth:160
    },
    {
      label:'门店',
      prop:'name',
      minWidth:172
    },
  ])
  return {
    tableLoading,
    tableData,
    handlerSearch,
    tableConfig
  }
}